# -*- coding: utf-8 -*-#
#-------------------------------------------------------------------------------
# 建立者:        潘炎珍  
# Name:         demo02
# Description:
# Author:       98745
# Date:         2019/6/7
#-------------------------------------------------------------------------------

from flask import Flask

app=Flask(__name__)
@app.route('/')
def index():
    return '<h1>root</h1>'

@app.route('/greet')
def greet():
    return '<h1>hello everyone</h1>'

@app.route('/greet/lining1')
def greetlining():
    return '<h1>hello lining</h1>'

@app.route('/greet/<name>')
def greetname(name):
    return '<h1>hello my {}</h1>'.format(name)

@app.route('/greet/<a1>/<a2>/<a3>')
def arg1(a1,a2,a3):
    return '<h1>{},{},{}</h1>'.format(a1,a2,a3)

@app.route('/greet/<a1>-<a2>-<a3>')
def arg2(a1,a2,a3):
    return '<h1>{}*{}*{}</h1>'.format(a1,a2,a3)

if __name__ == '__main__':
    app.run()
